74 WDT_A_hold(WDT_A_BASE);
86 GPIO_setAsPeripheralModuleFunctionInputPin(
88 GPIO_PIN4 + GPIO_PIN5,
89 GPIO_PRIMARY_MODULE_FUNCTION
94 CS_turnOnXT1(CS_XT1_DRIVE_0);
97 currentTime.Seconds = 0x00;
98 currentTime.Minutes = 0x26;
99 currentTime.Hours = 0x13;
100 currentTime.DayOfWeek = 0x03;
101 currentTime.DayOfMonth = 0x20;
102 currentTime.Month = 0x07;
103 currentTime.Year = 0x2011;
111 RTC_B_initCalendar(RTC_B_BASE,
117 RTC_B_configureCalendarAlarmParam
param = {0};
118 param.minutesAlarm = 0x00;
119 param.hoursAlarm = 0x17;
120 param.dayOfWeekAlarm = RTC_B_ALARMCONDITION_OFF;
121 param.dayOfMonthAlarm = 0x05;
122 RTC_B_configureCalendarAlarm(RTC_B_BASE, &
param);
125 RTC_B_setCalendarEvent(RTC_B_BASE,
126 RTC_B_CALENDAREVENT_MINUTECHANGE);
132 RTC_B_clearInterrupt(RTC_B_BASE,
133 RTCRDYIE + RTCTEVIE + RTCAIE);
135 RTC_B_enableInterrupt(RTC_B_BASE,
136 RTCRDYIE + RTCTEVIE + RTCAIE);
139 RTC_B_startClock(RTC_B_BASE);
142 __bis_SR_register(LPM0_bits + GIE);
146 #if defined(__TI_COMPILER_VERSION__) || defined(__IAR_SYSTEMS_ICC__)
147 #pragma vector=RTC_VECTOR
149 #elif defined(__GNUC__)
150 __attribute__((interrupt(RTC_VECTOR)))
154 switch (__even_in_range(RTCIV,16)){
158 GPIO_toggleOutputOnPin(
167 newTime = RTC_B_getCalendarTime(RTC_B_BASE);
MPU_initThreeSegmentsParam param
volatile Calendar newTime